package com.example.ordersystem.domain;



import java.io.File;
import java.io.Serializable;

/**
 * dishinfo作为视图,存放在mysql数据库中
 */
public class DishInfo implements Serializable {
    public static final String PICTURE_PATH = "/DishPictures";

    /**菜品编号*/
    private int num;

    /**分类名称*/

    private String cName;

    /**菜品名称*/

    private String dName;


    /**菜品价格*/

    private int price;

    /**菜品图片*/

    private String picture;

    /**菜品描述*/

    private String description;

    public DishInfo() {
        super();
    }

    public DishInfo(int num, String cName, String dName, int price, String picture, String description) {
        super();
        this.num = num;
        this.cName = cName;
        this.dName = dName;
        this.price = price;
        this.picture = picture;
        this.description = description;
    }

    public String getDisplayPicture() {
        return PICTURE_PATH.concat(File.separator).concat(picture);
    }

    public int getNum() {
        return num;
    }

    public void setNum(int num) {
        this.num = num;
    }

    public String getcName() {
        return cName;
    }

    public void setcName(String cName) {
        this.cName = cName;
    }

    public String getdName() {
        return dName;
    }

    public void setdName(String dName) {
        this.dName = dName;
    }

    public int getPrice() {
        return price;
    }

    public void setPrice(int price) {
        this.price = price;
    }

    public String getPicture() {
        return picture;
    }

    public void setPicture(String picture) {
        this.picture = picture;
    }

    public String getDescription() {
        return description;
    }

    public void setDescription(String description) {
        this.description = description;
    }
}
